#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QPushButton>
#include <QPainter>
#include <QDebug>
#include <QLabel>
#include <QTime>
#include <QMenuBar>
#include <QAction>
#include <QTimer>
#include "startpushbutton.h"
#include "unknownpushbutton.h"
#include "board.h"
#include "recodewidget.h"
#include "showwidget.h"

QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();
    void turnUpUnknownPushButton(int x, int y);
    void turnLeftUnknownPushButton(int x, int y);
    void turnRightUnknownPushButton(int x, int y);
    void turnDownUnknownPushButton(int x, int y);
    void turnOtherUnknownPushButton(int x, int y);
    void showMine(void);
    bool isWin(void);
    void Win(void);

private:
    Ui::MainWindow *ui;
    Board* map;
    UnknownPushButton* mineBoard[10][10];
    StartPushButton* startBtn;
    QTimer* qtime;
    int m_time;
    RecodeWidget* recodeWidget;
    ShowWidget* showWdiget;
};
#endif // MAINWINDOW_H
